﻿<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="CascadingDropDownList.ascx.cs" ClassName="CascadingDropDownList" Inherits="Hxsoft.AppV1._Controls.CascadingDropDownList" %>
<span id="<%= ValueContainerID %>">
	<asp:HiddenField ID="CtrSelectorValue" runat="server" />
</span>
<asp:HiddenField ID="CtrSelectorValues" runat="server" />
<span id="<%= this.ClientID %>_SelectorContainer"></span>
<script type="text/javascript">
function <%= this.ClientID %>_Init(){
	$("#<%= CtrSelectorValue.ClientID %>").cascadingDropDownList({selectorContainer : "#<%= this.ClientID %>_SelectorContainer"
		, valuesField : "#<%= CtrSelectorValues.ClientID %>"
		, loadDataUrl : "<%= LoadDataUrl %>"
		, initSelectorAmount : <%= InitSelectorAmount %>
		, onlySelectLeaf : <%= OnlySelectLeaf ? "true" : "false" %>
		, valueSeparator : "<%= Hxsoft.StringExtensions.ToJavascriptString(ValueSeparator) %>"
		, loadingText : "<%= LoadingText %>"
		, customPromptText : "<%= CustomPromptText %>"
		, promptTexts : [<%= (PromptTexts != null && PromptTexts.Length > 0) ? @"""" + Hxsoft.StringExtensions.Join(PromptTexts, @""", """) + @"""" : "" %>]});
}
</script>